import {Injectable} from '@angular/core';
import {BaseHttpService} from "../base-http.service";
import {Observable} from "rxjs";

export interface OtherInformationAddEdit {
  id?: number;
  dangerTypeKey: string;
  dangerTypeMinor: string;
  packageType: string;
  fireDangerType: string;
  remark: string;
}

@Injectable({
  providedIn: 'root'
})
export class OtherInformationService {

  constructor(public http: BaseHttpService) {
  }

  editOtherInformation(param: OtherInformationAddEdit): Observable<void> {
    return this.http.put('/identify/other', param, {needSuccessInfo: true});
  }


  getOtherInformationDetail(id: number): Observable<OtherInformationAddEdit> {
    return this.http.get(`/identify/other/${id}`)
  }

}
